package model

type GetProfessionReq struct {
	BelongToID *uint  `form:"belong_to_id"`
	Tier       string `form:"tier" validate:"omitempty,oneof=first second third"` // 所在的层级，可以直接获取该层的信息
	Name       string `form:"name"`
}

type Profession struct {
	Id         uint   `json:"id"`
	Name       string `json:"name"`
	Tier       string `json:"tier"`
	BelongToID *uint  `json:"belong_to_id"`
}

type GetProfessionResp struct {
	Total       int          `json:"total"`
	Professions []Profession `json:"professions"`
}

type CreateProfessionReq struct {
	BelongToID *uint  `json:"belong_to_id"`
	Tier       string `json:"tier" validate:"required,oneof=first second third"`
	Name       string `json:"name" validate:"required"`
}

type UpdateProfessionReq struct {
	Id   uint   `json:"id" validate:"required"`
	Name string `json:"name"`
	Tier string `json:"tier" validate:"oneof=first second third"`
}

type DeleteProfessionReq struct {
	Id uint `json:"id" form:"id" validate:"required"`
}
